#pragma once
#pragma warning (disable:4786)
// Wrapper Container for all GameObjects.

#include <vector>
#include"GameObject.h"
#include"BaseEntity.h"
#include"DXLightManager.h"
#include "Projectile3D.h"

//forward Declares
class GameObject;
class Player;
class Enemy;
class Model;
class Enemy;
class BaseEntity;

#define EntMgr EntityManager::Instance()

class EntityManager
{
protected:

	std::vector <GameObject*> objects;

	Player  *m_player;
	Enemy	*m_enemy1;
	Enemy	*m_enemy2;
	Enemy	*m_enemy3;
	Enemy	*m_enemy4;

	DXLightManager dxLtMgr;

	int lightID;
	float m_dt;


public:

	EntityManager();
	~EntityManager();
	static EntityManager* Instance();
	GameObject* GetEntityFromID(int);
	void draw();
	void update(float);
	void EntInput();
	float distFormula(D3DXVECTOR3, D3DXVECTOR3);
	float sumRadius(float, float);
	void collision();
	void CombatSystem();
	bool createGameObjects();
	void createPlayer();
	void createEnemy();
	void projectileSystem();
	void shutDown();
	void opTimer();
    void chargeOk();
	bool gameOver();
};